<template>
	<div class="md">
		<div class="plugins-tips">
			<h4>{{ pnode.id }} : {{ pnode.label }}</h4>
			<h4>{{plink.category}} {{plink.source.id}}:{{ plink.source.label }}  &rarr; {{plink.target.id}}: {{ plink.target.label }}</h4>
		</div>
		<md-editor class="mgb20" v-model="pnode.note" @on-upload-img="onUploadImg" style="height: 650px;width: 100%;" />
		<el-button type="primary">提交</el-button>
	</div>
</template>

<script setup lang="ts" name="md">
import MdEditor  from 'md-editor-v3';
import 'md-editor-v3/lib/style.css';




interface Node {
  id: string;
  label: string;
  groups: string;
  note: string;
}
const props = defineProps<{
	pnode: {
		id: string,
		groups: string,
		note: string,
		label: string
	},
	plink: {
		source: string;
		target: string;
		category: string;
	}
}>();


const onUploadImg = (files: any) => {
	console.log(files);
};




</script>
<style lang="scss">
  .plugins-tips {
    margin: 0px !important;
	padding: 0px !important;
  }
</style>